package net.lahuobao.mall.service.admin;

import net.lahuobao.mall.entity.admin.MallEcardRebateEntity;
import net.lahuobao.mall.entity.admin.MallOrderEntity;
import net.lahuobao.mall.entity.admin.MallOrderdetailEntity;
import net.lahuobao.mall.entity.admin.querymodel.MallEcardRebateModel;
import org.jeecgframework.core.common.model.json.AjaxJson;
import org.jeecgframework.core.common.service.CommonService;

import java.io.UnsupportedEncodingException;
import java.util.List;
import java.util.Map;

public interface MallEcardRebateServiceI extends CommonService{

    /**
     * 查询订单详情
     * @param ids
     * @return
     */
    Map<MallOrderEntity, List<MallOrderdetailEntity>>  selectOrderDetailByOrderIds(Integer[] ids);


    /**
     * 保存E卡返点
     * @param rebateEntity
     * @param orderIds
     */
    AjaxJson rebate(MallEcardRebateEntity rebateEntity, String orderIds) throws UnsupportedEncodingException;


    /**
     * e卡返点退回
     * @param rebateEntity
     */
    AjaxJson rebateReturn(MallEcardRebateEntity rebateEntity) throws Exception;

    /**
     * 查询订单详情
     * @param id
     * @return
     */
    Map<MallOrderEntity, List<MallOrderdetailEntity>>  selectOrderDetailById(Integer id);


    /**
     * e卡返点，退回审核
     * @param mallEcardRebate
     * @return
     */
    AjaxJson audit(MallEcardRebateEntity mallEcardRebate);


    /**
     * 根据条件查询
     * @param query
     * @return
     */
    List<MallEcardRebateModel> selectRebateListByquery(MallEcardRebateModel query);

}
